3.129 \(\int \frac {c+d x^2+e x^4+f x^6}{x^4 (a+b x^2)^2} \, dx\)

Optimal. Leaf size=121 \[ \frac {2 b c-a d}{a^3 x}+\frac {x \left (\frac {b^2 c}{a^2}-\frac {b d}{a}-\frac {a f}{b}+e\right )}{2 a \left (a+b x^2\right )}-\frac {c}{3 a^2 x^3}+\frac {\tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right ) \left (a^3 f+a^2 b e-3 a b^2 d+5 b^3 c\right )}{2 a^{7/2} b^{3/2}} \]

[Out]

-1/3*c/a^2/x^3+(-a*d+2*b*c)/a^3/x+1/2*(b^2*c/a^2-b*d/a+e-a*f/b)*x/a/(b*x^2+a)+1/2*(a^3*f+a^2*b*e-3*a*b^2*d+5*b
^3*c)*arctan(x*b^(1/2)/a^(1/2))/a^(7/2)/b^(3/2)

________________________________________________________________________________________

Rubi [A]  time = 0.16, antiderivative size = 121, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, integrand size = 30, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.100, Rules used = {1805, 1261, 205} \[ \frac {x \left (\frac {b^2 c}{a^2}-\frac {b d}{a}-\frac {a f}{b}+e\right )}{2 a \left (a+b x^2\right )}+\frac {\tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right ) \left (a^2 b e+a^3 f-3 a b^2 d+5 b^3 c\right )}{2 a^{7/2} b^{3/2}}+\frac {2 b c-a d}{a^3 x}-\frac {c}{3 a^2 x^3} \]

Antiderivative was successfully verified.

[In]

Int[(c + d*x^2 + e*x^4 + f*x^6)/(x^4*(a + b*x^2)^2),x]

[Out]

-c/(3*a^2*x^3) + (2*b*c - a*d)/(a^3*x) + (((b^2*c)/a^2 - (b*d)/a + e - (a*f)/b)*x)/(2*a*(a + b*x^2)) + ((5*b^3
*c - 3*a*b^2*d + a^2*b*e + a^3*f)*ArcTan[(Sqrt[b]*x)/Sqrt[a]])/(2*a^(7/2)*b^(3/2))

Rule 205

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]*ArcTan[x/Rt[a/b, 2]])/a, x] /; FreeQ[{a, b}, x]
&& PosQ[a/b]

Rule 1261

Int[((f_.)*(x_))^(m_.)*((d_) + (e_.)*(x_)^2)^(q_.)*((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4)^(p_.), x_Symbol] :> In
t[ExpandIntegrand[(f*x)^m*(d + e*x^2)^q*(a + b*x^2 + c*x^4)^p, x], x] /; FreeQ[{a, b, c, d, e, f, m, q}, x] &&
 NeQ[b^2 - 4*a*c, 0] && IGtQ[p, 0] && IGtQ[q, -2]

Rule 1805

Int[(Pq_)*((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^2)^(p_), x_Symbol] :> With[{Q = PolynomialQuotient[(c*x)^m*Pq,
 a + b*x^2, x], f = Coeff[PolynomialRemainder[(c*x)^m*Pq, a + b*x^2, x], x, 0], g = Coeff[PolynomialRemainder[
(c*x)^m*Pq, a + b*x^2, x], x, 1]}, Simp[((a*g - b*f*x)*(a + b*x^2)^(p + 1))/(2*a*b*(p + 1)), x] + Dist[1/(2*a*
(p + 1)), Int[(c*x)^m*(a + b*x^2)^(p + 1)*ExpandToSum[(2*a*(p + 1)*Q)/(c*x)^m + (f*(2*p + 3))/(c*x)^m, x], x],
 x]] /; FreeQ[{a, b, c}, x] && PolyQ[Pq, x] && LtQ[p, -1] && ILtQ[m, 0]

Rubi steps

\begin {align*} \int \frac {c+d x^2+e x^4+f x^6}{x^4 \left (a+b x^2\right )^2} \, dx &=\frac {\left (\frac {b^2 c}{a^2}-\frac {b d}{a}+e-\frac {a f}{b}\right ) x}{2 a \left (a+b x^2\right )}-\frac {\int \frac {-2 c+2 \left (\frac {b c}{a}-d\right ) x^2+\left (-\frac {b^2 c}{a^2}+\frac {b d}{a}-e-\frac {a f}{b}\right ) x^4}{x^4 \left (a+b x^2\right )} \, dx}{2 a}\\ &=\frac {\left (\frac {b^2 c}{a^2}-\frac {b d}{a}+e-\frac {a f}{b}\right ) x}{2 a \left (a+b x^2\right )}-\frac {\int \left (-\frac {2 c}{a x^4}-\frac {2 (-2 b c+a d)}{a^2 x^2}+\frac {-5 b^3 c+3 a b^2 d-a^2 b e-a^3 f}{a^2 b \left (a+b x^2\right )}\right ) \, dx}{2 a}\\ &=-\frac {c}{3 a^2 x^3}+\frac {2 b c-a d}{a^3 x}+\frac {\left (\frac {b^2 c}{a^2}-\frac {b d}{a}+e-\frac {a f}{b}\right ) x}{2 a \left (a+b x^2\right )}+\frac {\left (5 b^3 c-3 a b^2 d+a^2 b e+a^3 f\right ) \int \frac {1}{a+b x^2} \, dx}{2 a^3 b}\\ &=-\frac {c}{3 a^2 x^3}+\frac {2 b c-a d}{a^3 x}+\frac {\left (\frac {b^2 c}{a^2}-\frac {b d}{a}+e-\frac {a f}{b}\right ) x}{2 a \left (a+b x^2\right )}+\frac {\left (5 b^3 c-3 a b^2 d+a^2 b e+a^3 f\right ) \tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right )}{2 a^{7/2} b^{3/2}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.08, size = 125, normalized size = 1.03 \[ \frac {2 b c-a d}{a^3 x}-\frac {c}{3 a^2 x^3}-\frac {x \left (a^3 f-a^2 b e+a b^2 d-b^3 c\right )}{2 a^3 b \left (a+b x^2\right )}+\frac {\tan ^{-1}\left (\frac {\sqrt {b} x}{\sqrt {a}}\right ) \left (a^3 f+a^2 b e-3 a b^2 d+5 b^3 c\right )}{2 a^{7/2} b^{3/2}} \]

Antiderivative was successfully verified.

[In]

Integrate[(c + d*x^2 + e*x^4 + f*x^6)/(x^4*(a + b*x^2)^2),x]

[Out]

-1/3*c/(a^2*x^3) + (2*b*c - a*d)/(a^3*x) - ((-(b^3*c) + a*b^2*d - a^2*b*e + a^3*f)*x)/(2*a^3*b*(a + b*x^2)) +
((5*b^3*c - 3*a*b^2*d + a^2*b*e + a^3*f)*ArcTan[(Sqrt[b]*x)/Sqrt[a]])/(2*a^(7/2)*b^(3/2))

________________________________________________________________________________________

fricas [A]  time = 0.75, size = 378, normalized size = 3.12 \[ \left [-\frac {4 \, a^{3} b^{2} c - 6 \, {\left (5 \, a b^{4} c - 3 \, a^{2} b^{3} d + a^{3} b^{2} e - a^{4} b f\right )} x^{4} - 4 \, {\left (5 \, a^{2} b^{3} c - 3 \, a^{3} b^{2} d\right )} x^{2} + 3 \, {\left ({\left (5 \, b^{4} c - 3 \, a b^{3} d + a^{2} b^{2} e + a^{3} b f\right )} x^{5} + {\left (5 \, a b^{3} c - 3 \, a^{2} b^{2} d + a^{3} b e + a^{4} f\right )} x^{3}\right )} \sqrt {-a b} \log \left (\frac {b x^{2} - 2 \, \sqrt {-a b} x - a}{b x^{2} + a}\right )}{12 \, {\left (a^{4} b^{3} x^{5} + a^{5} b^{2} x^{3}\right )}}, -\frac {2 \, a^{3} b^{2} c - 3 \, {\left (5 \, a b^{4} c - 3 \, a^{2} b^{3} d + a^{3} b^{2} e - a^{4} b f\right )} x^{4} - 2 \, {\left (5 \, a^{2} b^{3} c - 3 \, a^{3} b^{2} d\right )} x^{2} - 3 \, {\left ({\left (5 \, b^{4} c - 3 \, a b^{3} d + a^{2} b^{2} e + a^{3} b f\right )} x^{5} + {\left (5 \, a b^{3} c - 3 \, a^{2} b^{2} d + a^{3} b e + a^{4} f\right )} x^{3}\right )} \sqrt {a b} \arctan \left (\frac {\sqrt {a b} x}{a}\right )}{6 \, {\left (a^{4} b^{3} x^{5} + a^{5} b^{2} x^{3}\right )}}\right ] \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((f*x^6+e*x^4+d*x^2+c)/x^4/(b*x^2+a)^2,x, algorithm="fricas")

[Out]

[-1/12*(4*a^3*b^2*c - 6*(5*a*b^4*c - 3*a^2*b^3*d + a^3*b^2*e - a^4*b*f)*x^4 - 4*(5*a^2*b^3*c - 3*a^3*b^2*d)*x^
2 + 3*((5*b^4*c - 3*a*b^3*d + a^2*b^2*e + a^3*b*f)*x^5 + (5*a*b^3*c - 3*a^2*b^2*d + a^3*b*e + a^4*f)*x^3)*sqrt
(-a*b)*log((b*x^2 - 2*sqrt(-a*b)*x - a)/(b*x^2 + a)))/(a^4*b^3*x^5 + a^5*b^2*x^3), -1/6*(2*a^3*b^2*c - 3*(5*a*
b^4*c - 3*a^2*b^3*d + a^3*b^2*e - a^4*b*f)*x^4 - 2*(5*a^2*b^3*c - 3*a^3*b^2*d)*x^2 - 3*((5*b^4*c - 3*a*b^3*d +
 a^2*b^2*e + a^3*b*f)*x^5 + (5*a*b^3*c - 3*a^2*b^2*d + a^3*b*e + a^4*f)*x^3)*sqrt(a*b)*arctan(sqrt(a*b)*x/a))/
(a^4*b^3*x^5 + a^5*b^2*x^3)]

________________________________________________________________________________________

giac [A]  time = 0.48, size = 123, normalized size = 1.02 \[ \frac {{\left (5 \, b^{3} c - 3 \, a b^{2} d + a^{3} f + a^{2} b e\right )} \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \, \sqrt {a b} a^{3} b} + \frac {b^{3} c x - a b^{2} d x - a^{3} f x + a^{2} b x e}{2 \, {\left (b x^{2} + a\right )} a^{3} b} + \frac {6 \, b c x^{2} - 3 \, a d x^{2} - a c}{3 \, a^{3} x^{3}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((f*x^6+e*x^4+d*x^2+c)/x^4/(b*x^2+a)^2,x, algorithm="giac")

[Out]

1/2*(5*b^3*c - 3*a*b^2*d + a^3*f + a^2*b*e)*arctan(b*x/sqrt(a*b))/(sqrt(a*b)*a^3*b) + 1/2*(b^3*c*x - a*b^2*d*x
 - a^3*f*x + a^2*b*x*e)/((b*x^2 + a)*a^3*b) + 1/3*(6*b*c*x^2 - 3*a*d*x^2 - a*c)/(a^3*x^3)

________________________________________________________________________________________

maple [A]  time = 0.02, size = 182, normalized size = 1.50 \[ \frac {e x}{2 \left (b \,x^{2}+a \right ) a}+\frac {e \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \sqrt {a b}\, a}-\frac {b d x}{2 \left (b \,x^{2}+a \right ) a^{2}}-\frac {3 b d \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \sqrt {a b}\, a^{2}}+\frac {b^{2} c x}{2 \left (b \,x^{2}+a \right ) a^{3}}+\frac {5 b^{2} c \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \sqrt {a b}\, a^{3}}-\frac {f x}{2 \left (b \,x^{2}+a \right ) b}+\frac {f \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \sqrt {a b}\, b}-\frac {d}{a^{2} x}+\frac {2 b c}{a^{3} x}-\frac {c}{3 a^{2} x^{3}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((f*x^6+e*x^4+d*x^2+c)/x^4/(b*x^2+a)^2,x)

[Out]

-1/2/b*x/(b*x^2+a)*f+1/2/a*x/(b*x^2+a)*e-1/2/a^2*b*x/(b*x^2+a)*d+1/2/a^3*b^2*x/(b*x^2+a)*c+1/2/b/(a*b)^(1/2)*a
rctan(1/(a*b)^(1/2)*b*x)*f+1/2/a/(a*b)^(1/2)*arctan(1/(a*b)^(1/2)*b*x)*e-3/2/a^2*b/(a*b)^(1/2)*arctan(1/(a*b)^
(1/2)*b*x)*d+5/2/a^3*b^2/(a*b)^(1/2)*arctan(1/(a*b)^(1/2)*b*x)*c-1/3*c/a^2/x^3-1/a^2/x*d+2/a^3/x*b*c

________________________________________________________________________________________

maxima [A]  time = 3.02, size = 130, normalized size = 1.07 \[ \frac {3 \, {\left (5 \, b^{3} c - 3 \, a b^{2} d + a^{2} b e - a^{3} f\right )} x^{4} - 2 \, a^{2} b c + 2 \, {\left (5 \, a b^{2} c - 3 \, a^{2} b d\right )} x^{2}}{6 \, {\left (a^{3} b^{2} x^{5} + a^{4} b x^{3}\right )}} + \frac {{\left (5 \, b^{3} c - 3 \, a b^{2} d + a^{2} b e + a^{3} f\right )} \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{2 \, \sqrt {a b} a^{3} b} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((f*x^6+e*x^4+d*x^2+c)/x^4/(b*x^2+a)^2,x, algorithm="maxima")

[Out]

1/6*(3*(5*b^3*c - 3*a*b^2*d + a^2*b*e - a^3*f)*x^4 - 2*a^2*b*c + 2*(5*a*b^2*c - 3*a^2*b*d)*x^2)/(a^3*b^2*x^5 +
 a^4*b*x^3) + 1/2*(5*b^3*c - 3*a*b^2*d + a^2*b*e + a^3*f)*arctan(b*x/sqrt(a*b))/(sqrt(a*b)*a^3*b)

________________________________________________________________________________________

mupad [B]  time = 0.13, size = 119, normalized size = 0.98 \[ \frac {\mathrm {atan}\left (\frac {\sqrt {b}\,x}{\sqrt {a}}\right )\,\left (f\,a^3+e\,a^2\,b-3\,d\,a\,b^2+5\,c\,b^3\right )}{2\,a^{7/2}\,b^{3/2}}-\frac {\frac {c}{3\,a}+\frac {x^2\,\left (3\,a\,d-5\,b\,c\right )}{3\,a^2}-\frac {x^4\,\left (-f\,a^3+e\,a^2\,b-3\,d\,a\,b^2+5\,c\,b^3\right )}{2\,a^3\,b}}{b\,x^5+a\,x^3} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((c + d*x^2 + e*x^4 + f*x^6)/(x^4*(a + b*x^2)^2),x)

[Out]

(atan((b^(1/2)*x)/a^(1/2))*(5*b^3*c + a^3*f - 3*a*b^2*d + a^2*b*e))/(2*a^(7/2)*b^(3/2)) - (c/(3*a) + (x^2*(3*a
*d - 5*b*c))/(3*a^2) - (x^4*(5*b^3*c - a^3*f - 3*a*b^2*d + a^2*b*e))/(2*a^3*b))/(a*x^3 + b*x^5)

________________________________________________________________________________________

sympy [A]  time = 25.99, size = 212, normalized size = 1.75 \[ - \frac {\sqrt {- \frac {1}{a^{7} b^{3}}} \left (a^{3} f + a^{2} b e - 3 a b^{2} d + 5 b^{3} c\right ) \log {\left (- a^{4} b \sqrt {- \frac {1}{a^{7} b^{3}}} + x \right )}}{4} + \frac {\sqrt {- \frac {1}{a^{7} b^{3}}} \left (a^{3} f + a^{2} b e - 3 a b^{2} d + 5 b^{3} c\right ) \log {\left (a^{4} b \sqrt {- \frac {1}{a^{7} b^{3}}} + x \right )}}{4} + \frac {- 2 a^{2} b c + x^{4} \left (- 3 a^{3} f + 3 a^{2} b e - 9 a b^{2} d + 15 b^{3} c\right ) + x^{2} \left (- 6 a^{2} b d + 10 a b^{2} c\right )}{6 a^{4} b x^{3} + 6 a^{3} b^{2} x^{5}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((f*x**6+e*x**4+d*x**2+c)/x**4/(b*x**2+a)**2,x)

[Out]

-sqrt(-1/(a**7*b**3))*(a**3*f + a**2*b*e - 3*a*b**2*d + 5*b**3*c)*log(-a**4*b*sqrt(-1/(a**7*b**3)) + x)/4 + sq
rt(-1/(a**7*b**3))*(a**3*f + a**2*b*e - 3*a*b**2*d + 5*b**3*c)*log(a**4*b*sqrt(-1/(a**7*b**3)) + x)/4 + (-2*a*
*2*b*c + x**4*(-3*a**3*f + 3*a**2*b*e - 9*a*b**2*d + 15*b**3*c) + x**2*(-6*a**2*b*d + 10*a*b**2*c))/(6*a**4*b*
x**3 + 6*a**3*b**2*x**5)

________________________________________________________________________________________